﻿.multi-select {
    width: 100%;
    position: relative;
    border-radius: 4px;
}

    .multi-select.disabled {
        background-color: #eee;
    }

.multi-select-toggle {
    border: solid 1px #ddd;
    border-radius: 4px;
    cursor: pointer;
    min-height: 35px;
    max-height: 70px;
    overflow: auto;
}

    .multi-select-toggle.disabled {
        cursor: not-allowed;
    }

    .multi-select-toggle .clear {
        padding: 7px 0.25rem;
        display: none;
        color: #adb5bd;
    }

        .multi-select-toggle .clear:hover {
            background-color: #ddd;
            border-radius: 4px;
        }

    .multi-select-toggle .dropdown {
        padding: 7px 0.25rem;
        display: block;
    }

    .multi-select-toggle.selected .clear {
        display: block;
    }

    .multi-select-toggle.selected .dropdown,
    .multi-select-toggle.disabled .clear {
        display: none;
    }

    .multi-select-toggle .append {
        position: absolute;
        height: 100%;
        width: 30px;
        right: 0;
        top: 0;
        color: #c0c4cc;
        display: flex;
        align-items: center;
        justify-content: center;
    }

        .multi-select-toggle .append .dropdown {
            transition: all .3s;
            transform: rotate(180deg);
        }

.show .multi-select-toggle .append .dropdown {
    transform: rotate(0);
}

.multi-select-items {
    display: flex;
    flex-wrap: wrap;
    padding-top: 3px;
    padding-left: 3px;
    position: relative;
}

    .multi-select-items span {
        border: solid 1px #ddd;
        border-radius: 4px;
        padding: 2px 6px;
        background-color: #e9ecef;
        margin-bottom: 3px;
    }

    .multi-select-items .multi-select-item {
        display: inline-block;
        max-width: 130px;
        text-overflow: ellipsis;
        overflow: hidden;
        white-space: nowrap;
        margin-right: 3px;
    }

    .multi-select-items .multi-select-item-group {
        display: inline-flex;
        position: relative;
    }

        .multi-select-items .multi-select-item-group .multi-select-item {
            padding-left: 9px;
        }

    .multi-select-items .multi-select-close {
        border-top-right-radius: 0;
        border-bottom-right-radius: 0;
        margin-right: -3px;
        z-index: 2;
        transition: color .3s linear, background-color .3s linear;
    }

        .multi-select-items .multi-select-close:hover {
            color: #333;
            background-color: #ddd;
        }

.multi-select-menu {
    margin-top: 10px;
    max-height: 274px;
    padding: 0.25rem 0;
    width: 100%;
    font-size: inherit;
    cursor: pointer;
    overflow: auto;
    box-shadow: 0 2px 12px 0 rgba(0,0,0,.1);
    background-color: #fff;
    background-clip: padding-box;
    border: 1px solid rgba(0,0,0,.15);
    border-radius: .25rem;
    position: absolute;
    z-index: 1000;
    display: none;
}

.multi-select.show .multi-select-menu,
.multi-select.show .multi-select-menu-arrow {
    display: block;
}

.multi-select-menu .toolbar {
    padding: 6px 10px;
}

    .multi-select-menu .toolbar .btn {
        line-height: 12px;
        padding: 7px 15px;
        border: 1px solid #dee2e6;
        transition: border-color .3s linear, color .3s linear;
    }

        .multi-select-menu .toolbar .btn:hover {
            border-color: #409eff;
            color: #409eff;
        }

        .multi-select-menu .toolbar .btn:not(:last-child) {
            margin-right: 1rem;
        }

.multi-select-menu .search {
    padding: 7px 10px;
    position: relative;
}

    .multi-select-menu .search .search-text {
        width: 100%;
        padding-right: 30px;
    }

    .multi-select-menu .search .fa-search {
        position: absolute;
        left: calc(100% - 34px);
        top: 18px;
        color: #adb5bd;
    }

.multi-select-menu-item {
    display: flex;
    padding: 0 10px;
    align-items: center;
    transition: all .3s linear;
}

    .multi-select-menu-item.active {
        background-color: #dee2e6;
    }

    .multi-select-menu-item:hover {
        background-color: #6fd6e6;
    }

    .multi-select-menu-item > span {
        padding: 0.375rem 0.75rem;
    }

.form-inline .multi-select-menu-item .checkbox-label {
    display: none;
}

@media (min-width: 576px) {
    .form-inline .multi-select {
        width: 196px;
    }
}

.multi-select-ph {
    padding: 0 1rem;
    color: #c0c4cc;
    line-height: 35px;
    position: absolute;
}

.multi-select .multi-select-menu-arrow {
    width: 0;
    height: 0;
    border-width: 0 6px 6px;
    border-style: solid;
    border-color: transparent transparent rgba(0,0,0,.15);
    position: absolute;
    left: 20px;
    margin-top: 4px;
    z-index: 1001;
    display: none;
}

    .multi-select .multi-select-menu-arrow:after {
        content: " ";
        width: 0;
        height: 0;
        border-width: 0 6px 6px;
        border-style: solid;
        border-color: transparent transparent #fff;
        position: absolute;
        top: 1px;
        left: -6px;
    }
